package com.bonjour.work.dto;

public class BasePage {
    private int size;
    private int pager;

    private int offSet;

    public int getOffSet() {
        return this.size * this.pager;
    }

    public void setOffSet(int offSet) {
        this.offSet = offSet;
    }

    public int getPager() {
        return pager;
    }

    public void setPager(int pager) {
        if (pager <= 0) {
            this.pager = 0;
        } else {
            this.pager = pager - 1;
        }
    }

    public int getSize() {
        return size;
    }

    public void setSize(int size) {
        if (size <= 0) {
            this.size = 0;
        } else {
            this.size = size;
        }
    }
}
